package com.example.activitydemo

import android.os.Bundle
import android.util.Log
import androidx.activity.ComponentActivity

/**
 *@author: njb
 *@date:  2023/3/21 0:16
 *@desc:
 */
class DialogActivity :ComponentActivity(){
    private val TAG = "DialogActivity生命周期"
    override fun onCreate(savedInstanceState: Bundle?) {
        super.onCreate(savedInstanceState)
        setContentView(R.layout.activity_main)
        Log.d(TAG,"--onCreate--" + "---DialogActivity创建了---")
    }

    override fun onRestart() {
        super.onRestart()
        Log.d(TAG,"--onRestart-" + "---DialogActivity重新创建了---")
    }

    override fun onResume() {
        super.onResume()
        Log.d(TAG,"--onResume--" + "---DialogActivity已经可见了---")
    }

    override fun onStart() {
        super.onStart()
        Log.d(TAG,"--onStart--" + "---DialogActivity已经启动了---")
    }

    override fun onPause() {
        super.onPause()
        Log.d(TAG,"--onPause--" + "---DialogActivity已经暂停了---")
    }

    override fun onStop() {
        super.onStop()
        Log.d(TAG,"--onStop--" + "---DialogActivity已经停止了---")
    }

    override fun onDestroy() {
        super.onDestroy()
        Log.d(TAG,"--onDestroy--" + "---DialogActivity已经销毁了---")
    }
}